<template>
  <div class="footer-home clearfix">
    <div class="con-width-1200 clearfix">
      <div class="fxl one clearfix">
        <h1>医院地址：北京市丰台区右安门外大街199号</h1>
      </div>
      <div class="fxl clearfix">
        <H1>服务热线：010-83322000; 83322548（咨询）; 83322619（投诉）; 15910941029（非工作时间）</H1>
        <h1>工作时间：8:30—11:30，13:30—17:00（工作日）</h1>
      </div>
      <!-- <div class="fxr two clearfix">
        <h1>官方微博</h1>
        <img class="img rad5" src="../assets/images/weixin.jpg">
      </div>-->
<!--      <div class="fxr two clearfix">-->
<!--        <h1>微信公众号</h1>-->
<!--        <img class="img rad5" src="../assets/images/weixin.jpg" />-->
<!--      </div>-->
      <div class="clear"></div>
      <ul class="link clearfix">
        <h1>友情链接：</h1>
        <li class="clearfix" v-for="(item, index) in list[0].sunList" :key="index">
          <a class="clearfix" :href="item.originUrl" target="_blank">
            <img :src="item.titleImg" class="img" />
          </a>
        </li>
        <!--  <li>卫生和计划生育委员会</li>
        <li>卫生和计划生育委员会</li>
        <li>卫生和计划生育委员会</li>
        <li>卫生和计划生育委员会</li>
        <li>卫生和计划生育委员会</li>
        <li>卫生和计划生育委员会</li>-->
      </ul>
    </div>
  </div>
</template>

<script>
import _http from "../httpService";

  export default {
    name: "Footer",
    props: {},
    data() {
      return {
        list: [
          {imgUrl: require("../assets/images/banner.jpg")},
          {imgUrl: require("../assets/images/banner.jpg")},
          {imgUrl: require("../assets/images/banner.jpg")},
        ],
      };
    },
    created() {
      // 初始化加载栏目等数据
      _http
          .get("/website/jcChannel/getChannelListByPc?parentCode=friendlyLink&pageSize=1000")
          .then((response) => {
            console.log(response);
            this.list = [];
            response.data.result.records.forEach((element) => {
              this.list.push({
                name: element.channelName,
                path: element.link,
                sunList: element.contentList,
              });
            });
          })
          .catch((error) => console.log(error))
          .finally(() => (this.loading = false));
    },
  };
</script>

<style lang="scss">
.footer-home {
  color: #fff;
  padding: 20px 0px;
  background: -webkit-linear-gradient(
    90deg,
    #109c9e,
    #8bd8da
  ); /* Safari 5.1 - 6.0 */
  background: -o-linear-gradient(
    90deg,
    #109c9e,
    #8bd8da
  ); /* Opera 11.1 - 12.0 */
  background: -moz-linear-gradient(
    90deg,
    #109c9e,
    #8bd8da
  ); /* Firefox 3.6 - 15 */
  background: linear-gradient(
    90deg,
    #109c9e,
    #8bd8da
  ); /* 标准的语法（必须放在最后） */
  h1 {
    font-size: 16px;
    text-align: left;
    line-height: 40px;
  }

  h2 {
    font-size: 14px;
    text-align: left;
    line-height: 40px;

    i {
      font-size: 16px;
    }
  }

  .one {
    margin-right: 100px;
  }

  .img {
    height: 80px;
    border: 3px solid #fff;
  }

  .two {
    margin-left: 30px;
  }

  .link {
    margin: 10px 0px 0px 0px;

    pre {
      float: left;
    }

    li {
      float: left;
      margin-right: 20px;
      margin-bottom: 10px;
      height: 50px;
      width: 183px;

      a {
        .img {
          border: 0px;
          background: #fff;
          width: 100%;
          height: 100%;
        }
      }
    }

    li:nth-child(7),
    li:nth-child(13),
    li:nth-child(19) {
      margin-right: 0px;
    }
  }
}
</style>
